package com.hotel.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;

/**
 * 
 * @TableName ht_member
 */
@TableName(value ="ht_member")
@Data
public class HtMember implements Serializable {
    /**
     * 会员编号
     */
    @TableId
    private Long memberNo;

    /**
     * 会员姓名
     */
    private String memberName;

    /**
     * 性别
     */
    private String memberSex;

    /**
     * 密码
     */
    private String memberPassword;

    /**
     * 电话
     */
    private Long memberPhone;

    /**
     * 地址
     */
    private String memberAddress;

    /**
     * 邮箱
     */
    private String memberEmail;

    /**
     * 积分
     */
    private Long memberIntegral;

    /**
     * 级别，普通、vip
     */
    private String memberLevel;

    /**
     * 最后一次入住时间
     */
    private Date checkInTime;

    /**
     * 最后一次预定时间
     */
    private Date bookTime;

    /**
     * 备注
     */
    private String memberRemark;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        HtMember other = (HtMember) that;
        return (this.getMemberNo() == null ? other.getMemberNo() == null : this.getMemberNo().equals(other.getMemberNo()))
            && (this.getMemberName() == null ? other.getMemberName() == null : this.getMemberName().equals(other.getMemberName()))
            && (this.getMemberSex() == null ? other.getMemberSex() == null : this.getMemberSex().equals(other.getMemberSex()))
            && (this.getMemberPassword() == null ? other.getMemberPassword() == null : this.getMemberPassword().equals(other.getMemberPassword()))
            && (this.getMemberPhone() == null ? other.getMemberPhone() == null : this.getMemberPhone().equals(other.getMemberPhone()))
            && (this.getMemberAddress() == null ? other.getMemberAddress() == null : this.getMemberAddress().equals(other.getMemberAddress()))
            && (this.getMemberEmail() == null ? other.getMemberEmail() == null : this.getMemberEmail().equals(other.getMemberEmail()))
            && (this.getMemberIntegral() == null ? other.getMemberIntegral() == null : this.getMemberIntegral().equals(other.getMemberIntegral()))
            && (this.getMemberLevel() == null ? other.getMemberLevel() == null : this.getMemberLevel().equals(other.getMemberLevel()))
            && (this.getCheckInTime() == null ? other.getCheckInTime() == null : this.getCheckInTime().equals(other.getCheckInTime()))
            && (this.getBookTime() == null ? other.getBookTime() == null : this.getBookTime().equals(other.getBookTime()))
            && (this.getMemberRemark() == null ? other.getMemberRemark() == null : this.getMemberRemark().equals(other.getMemberRemark()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getMemberNo() == null) ? 0 : getMemberNo().hashCode());
        result = prime * result + ((getMemberName() == null) ? 0 : getMemberName().hashCode());
        result = prime * result + ((getMemberSex() == null) ? 0 : getMemberSex().hashCode());
        result = prime * result + ((getMemberPassword() == null) ? 0 : getMemberPassword().hashCode());
        result = prime * result + ((getMemberPhone() == null) ? 0 : getMemberPhone().hashCode());
        result = prime * result + ((getMemberAddress() == null) ? 0 : getMemberAddress().hashCode());
        result = prime * result + ((getMemberEmail() == null) ? 0 : getMemberEmail().hashCode());
        result = prime * result + ((getMemberIntegral() == null) ? 0 : getMemberIntegral().hashCode());
        result = prime * result + ((getMemberLevel() == null) ? 0 : getMemberLevel().hashCode());
        result = prime * result + ((getCheckInTime() == null) ? 0 : getCheckInTime().hashCode());
        result = prime * result + ((getBookTime() == null) ? 0 : getBookTime().hashCode());
        result = prime * result + ((getMemberRemark() == null) ? 0 : getMemberRemark().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", memberNo=").append(memberNo);
        sb.append(", memberName=").append(memberName);
        sb.append(", memberSex=").append(memberSex);
        sb.append(", memberPassword=").append(memberPassword);
        sb.append(", memberPhone=").append(memberPhone);
        sb.append(", memberAddress=").append(memberAddress);
        sb.append(", memberEmail=").append(memberEmail);
        sb.append(", memberIntegral=").append(memberIntegral);
        sb.append(", memberLevel=").append(memberLevel);
        sb.append(", checkInTime=").append(checkInTime);
        sb.append(", bookTime=").append(bookTime);
        sb.append(", memberRemark=").append(memberRemark);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}